from __future__ import unicode_literals

from django.db import models


class AccgmUser(models.Model):
    name = models.CharField(max_length=32, blank=True, null=True)
    sex = models.CharField(max_length=32, blank=True, null=True)
    birthday = models.CharField(max_length=32, blank=True, null=True)
    height = models.CharField(max_length=32, blank=True, null=True)
    weight = models.CharField(max_length=32, blank=True, null=True)
    checkmessage = models.IntegerField(db_column='checkMessage', blank=True, null=True)  # Field name made lowercase.
    earlobewidth = models.CharField(db_column='earlobeWidth', max_length=32, blank=True, null=True)  # Field name made lowercase.
    isearpiercing = models.CharField(db_column='isEarPiercing', max_length=32, blank=True, null=True)  # Field name made lowercase.
    password = models.CharField(max_length=32, blank=True, null=True)
    username = models.CharField(max_length=32, blank=True, null=True)
    addtime = models.DateTimeField(db_column='addTime', blank=True, null=True)  # Field name made lowercase.
    updatetime = models.DateTimeField(db_column='updateTime', blank=True, null=True)  # Field name made lowercase.

    class Meta:
        managed = False
        db_table = 'accgm_user'


class AccgmUserMessage(models.Model):
    userid = models.IntegerField(db_column='userId', blank=True, null=True)  # Field name made lowercase.
    collectloc = models.IntegerField(db_column='collectLoc', blank=True, null=True)  # Field name made lowercase.
    collect = models.IntegerField(blank=True, null=True)
    statetime = models.CharField(db_column='stateTime', max_length=32, blank=True, null=True)  # Field name made lowercase.
    state = models.CharField(max_length=32, blank=True, null=True)
    bodytemperature = models.CharField(db_column='bodyTemperature', max_length=32, blank=True, null=True)  # Field name made lowercase.
    bloodsugar1 = models.CharField(db_column='bloodSugar1', max_length=32, blank=True, null=True)  # Field name made lowercase.
    bloodsugar2 = models.CharField(db_column='bloodSugar2', max_length=32, blank=True, null=True)  # Field name made lowercase.
    bloodsugar3 = models.CharField(db_column='bloodSugar3', max_length=32, blank=True, null=True)  # Field name made lowercase.
    istakedownsugar = models.CharField(db_column='isTakeDownSugar', max_length=32, blank=True, null=True)  # Field name made lowercase.
    isinjectinsulin = models.CharField(db_column='isInjectInsulin', max_length=32, blank=True, null=True)  # Field name made lowercase.
    istakepainkiller = models.CharField(db_column='isTakePainKiller', max_length=32, blank=True, null=True)  # Field name made lowercase.
    sports = models.CharField(max_length=32, blank=True, null=True)
    dataurl = models.CharField(db_column='dataUrl', max_length=256, blank=True, null=True)  # Field name made lowercase.
    addtime = models.DateTimeField(db_column='addTime', blank=True, null=True)  # Field name made lowercase.
    updatetime = models.DateTimeField(db_column='updateTime', blank=True, null=True)  # Field name made lowercase.
    imei = models.CharField(db_column='imei', max_length=256, blank=True, null=True)  # Field name made lowercase.
    venderid = models.CharField(db_column='venderId', max_length=256, blank=True, null=True)  # Field name made lowercase.
    deviceid = models.CharField(db_column='deviceId', max_length=256, blank=True, null=True)  # Field name made lowercase.
    
    class Meta:
        managed = False
        db_table = 'accgm_user_message'
        
class AccgmBackgroundUser(models.Model):
    id = models.IntegerField(primary_key=True)
    username = models.CharField(max_length=256, blank=True, null=True)
    password = models.CharField(max_length=256, blank=True, null=True)
    addtime = models.DateTimeField(db_column='addTime', blank=True, null=True)  # Field name made lowercase.
    updatetime = models.DateTimeField(db_column='updateTime', blank=True, null=True)  # Field name made lowercase.

    class Meta:
        managed = False
        db_table = 'accgm_background_user'